package io.jft.doll.room.typeConverters

import android.arch.persistence.room.TypeConverter
import com.google.gson.Gson
import io.jft.doll.room.entity.common.RtmpREntity

class RoomRtmpConverters {
    @TypeConverter
    fun fromRtmpToString(value: RtmpREntity) = Gson().toJson(value)!!

    @TypeConverter
    fun stringToRtmp(value: String) = Gson().fromJson(value, RtmpREntity::class.java)!!
}